Re: Can"t locate loadable object for module Tk::Event
am 18.07.2005 17:55:01 von balu422
Sisyphus wrote:
>
> Is this just a web server issue ? What happens when you run from the command
> line:
>
> perl -MTk::Event -le 'print "OK"'
>
> If you get the same error, then one suspects that auto/Tk/Event/Event.so
> (which is the loadable object referred to) is not where it should be - ie in
> one of the @INC directories.
>
> If it's there, then one begins to wonder about permissions - of both the
> file itself, and the directory that houses it.
Yes, your suggestion worked. I didn't have the .so files in the @INC
directories. I copied the files and it worked. Thank you so much. I am
getting a different error when I click on one of the link that is:
Software error:
Undefined subroutine &main::Parse_Date called at
/opt/SUNWwbsvr/ssl/dodnic.portal/cgi-bin/aaa/aaamain.cgi line 118,
line 1.
For help, please send mail to this site's webmaster, giving this error
message and the time and date of the error.
[Mon Jul 18 11:45:55 2005] aaamain.cgi: Undefined subroutine
&main::Parse_Date called at
/opt/SUNWwbsvr/ssl/dodnic.portal/cgi-bin/aaa/aaamain.cgi line 118, line
1.
Please help me, if this is familiar.
Thanks a million,
Balu
Re: Can"t locate loadable object for module Tk::Event
am 19.07.2005 18:27:05 von balu422
Sisyphus wrote:
> wrote in message
> Perl can't find the Parse_Date() subroutine. Where is it ? If it's a
> Tk::Event subroutine, then calling it as Tk::Event::Parse_Date(), instead=
of
> simply Parse_Date(), should fix the problem. Alternatively, you could imp=
ort
> it - by loading Tk::Event with:
> use Tk::Event qw(Parse_Date);
Thanks for taking time to relply me. use Date::Calc qw(Parse_Date); is
already defined and still the browser is complaining that. My program
is as follows:
#!/usr/local/bin/perl
use CGI::Carp qw(fatalsToBrowser);
$ENV{'PATH'} =3D '/bin:/usr/bin:/usr/ucb';
@capodichino =3D ();
@vienna =3D ();
@vaihingen =3D ();
@kelly =3D ();
@wheeler =3D ();
@yokota =3D ();
@yydata =3D ();
use Chart::Plot;
use CGI qw (:standard);
use CGI::Carp qw(fatalsToBrowser);
use Chart::Lines;
use Date::Calc qw(Parse_Date);
use Date::Calc qw(Add_Delta_Days);
use Date::Calc qw(Delta_Days);
use AAA_UTILS;
$bad_input =3D 0;
$bad_input =3D 0;
$empty_flag =3D 0;
$visit =3D 0;
$xdata_flag =3D 0;
$last_xdata =3D 0;
$start_str_time =3D "";
$error =3D 0;
$yesterday =3D -1;
$yesterday2 =3D -2;
$select_header =3D 0;
main: {
$access_handle =3D AAA_UTILS->new();
Init();
page_starter();
if ( $q->param('Systems') =3D~ /Current month/) {
Current_month_form();
} elsif ( $q->param('Systems') =3D~ /Ad hoc/) {
adhoc_search_form();
adhoc_search_form();
} else { empty_form(); }
};
sub Init
{
use CGI;
$q=3Dnew CGI;
@start_month =3D qw (01 02 03 04 05 06 07 08 09 10 11 12);
@end_month =3D qw (01 02 03 04 05 06 07 08 09 10 11 12);
$default_option =3D "Incident Reports";
$default_system =3D "System Reports";
}
sub page_starter()
{
print $q->header;
print $q->start_html(-title=3D>'AAA System Reports',
-bgcolor =3D> "#FFFFFF"
);
}
sub empty_form() {
$empty =3D "Date";
local($user) =3D $ENV{'REMOTE_USER'};
$user_value =3D $user_table{$user};
print qq!
AAA System Reports
System Reports provide performance information.
target=3D"_blank">Current Month.
target=3D"_blank">AAA server events Ad hoc.
Previous Month for AAA server events Activity Reports -
Event activity is provided for:
AAA server events by hour.
AAA server events by Communications Server.
AAA server events by Communications Server by hour.
Communications Server Port Report - All activity at CS
ports.
!;
}
sub Current_month_form()
{
$empty =3D "Date";
Init_aaa();
($year1,$month1,$day1) =3D Parse_Date($access_handle->Sys=ADtem_date());
($year2, $month2, $day2) =3D Add_Delta_Days($year1, $month1, $day1,
$yesterday);
($year3, $month3, $day3) =3D Add_Delta_Days($year1, $month1, $day1,
$yesterday2)
;
@a =3D (
$q->start_form(
-action =3D> 'aaa.cgi'
),
$q->popup_menu(
-name =3D> 'AaaServerActivity', -values =3D> [@activity_lists]
),
-name =3D> 'AaaServerActivity', -values =3D> [@activity_lists]
),
$q->popup_menu(
-name =3D> 'ServerName', -values =3D> [@server_lists]
),
$q->popup_menu(
-name =3D> 'options', -values =3D> [@options], -default=3D>
$default_option
),
$q->popup_menu(
-name =3D> 'ReportType', -values =3D> [@report_lists]
),
$q->submit(
-name =3D> 'GetHistoricalData', -value=3D>'Get Report'),
$q->end_form()
);
printf <
Current Month
Activities
enter>
or =3D
"white"
width=3D75%>
%s
AAA Server Activity |
%s |
Server |
%s |
Period |
%s |
Report Type |
%s |
%s |
EOM
}
sub adhoc_search_form()
{
$empty =3D "Date";
@activity_lists =3D ('Events by Hour', 'Events by Day');
@server_lists =3D ('all servers', 'aaa-capodichino', 'aaa-kelly',
'aaa-vaihingen
', 'aaa-vienna', 'aaa-wheeler', 'aaa-yokota');
($year1,$month1,$day1) =3D Parse_Date($access_handle->Sys=ADtem_date());
($year2, $month2, $day2) =3D Add_Delta_Days($year1, $month1, $day1,
$yesterday);
($year3, $month3, $day3) =3D Add_Delta_Days($year1, $month1, $day1,
-8);
if ( $month2 < 10 ) {
$month2 =3D "0" . $month2;
}
if ( $month3 < 10 ) {
$month3 =3D "0" . $month3;
}
@a =3D (
$q->start_form(
-action =3D> 'adhoc.cgi'
),
$q->popup_menu(
-name =3D> 'AaaServerActivity', -values =3D> [@activity_lists]
),
$q->popup_menu(
-name =3D> 'ServerName', -values =3D> [@server_lists]
),
$q->popup_menu(
-name =3D> 'StartMonth',
-values =3D> [@start_month], -default=3D> $month2
),
$q->textfield(-name =3D> 'StartDay', -value =3D> $day3, -size=3D>2),
$q->textfield(-name =3D> 'StartYear', -value =3D> $year2, -size=3D>4),
$q->popup_menu(
-name =3D> 'EndMonth',
-values =3D> [@end_month], -default=3D> $month2
),
$q->textfield(-name =3D> 'EndDay', -value =3D> $day2, -size=3D>2),
$q->textfield(-name =3D> 'EndYear', -value =3D> $year2, -size=3D>4),
$q->submit(
-name =3D> 'GetHistoricalData', -value=3D>'Get Report'),
$q->end_form()
);
printf <
Ad Hoc AAA System
Reports
center>
or =3D
"white"
width=3D75%>
%s
AAA Server Activity |
%s |
Server |
%s |
$empty |
Month |
Date |
Year |
Start date |
%s |
%s |
%s |
End date |
%s |
%s |
%s |
%s |
EOM
}
sub Init_aaa()
{
use CGI;
$q=3Dnew CGI;
@start_month =3D qw (01 02 03 04 05 06 07 08 09 10 11 12);
@end_month =3D qw (01 02 03 04 05 06 07 08 09 10 11 12);
@server_lists =3D ('all servers', 'aaa-capodichino', 'aaa-kelly',
'aaa-vaihingen', 'aaa-vienna', 'aaa-wheeler', 'aaa-yokota');
@options =3D ('previous day', 'last 7 days', 'month to date');
$default_option =3D "previous day";
@activity_lists =3D ('Events by Hour', 'Events by Day',
'Events by Communications Server', 'Events by Communications
Server by H
our');
@report_lists =3D ('Graph', 'Table');
}
Please let me know if there is something I am overlooking.
Thanks,
Balu